/**
 * Created by Administrator on 2016/12/8.
 */
export const  allUrl =() => {
    var ajaxUrl;
    ajaxUrl='/api/v1/';
    return ajaxUrl;
};


export const  getQueryString =(name, url) => {

    if (!url) url = window.location.href;
    var reg = new RegExp("(^|\\?|&)"+ name +"=([^&]*)(\\s|&|$)", "i");
    if (reg.test(url)){
        return unescape(RegExp.$2.replace(/\+/g, " "));
    }else{
        return "";

    }
};